import React, { useEffect } from 'react';
import { connect } from 'umi';
import styles from './index.less';


const User: React.FC<any> = (props) => {
  const {dispatch} = props;
  useEffect(() => {
    dispatch({type: 'user/getData'});
  }, []);
  
  return (
    <div>
      <h1 className={styles.title}>Page user</h1>
    </div>
  );
}

export default connect(
  ({user}: any) => ({user})
)(User);